package category

type Category struct {
	ID int32 `uri:"id" binding:"required,gt=0"`
}

type Form struct {
	Name           string `form:"name" json:"name" binding:"required,min=3,max=20"`
	ParentCategory int32  `form:"parent_category" json:"parent_category"`
	Level          int32  `form:"level" json:"level" binding:"required,oneof=1 2 3"`
	IsTab          bool   `form:"is_tab" json:"is_tab" binding:"-"`
}

type UpdateForm struct {
	Name  string `form:"name" json:"name" binding:"required,min=3,max=20"`
	IsTab *bool  `form:"is_tab" json:"is_tab"`
}
